package com.up.kafka.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.HashMap;
import java.util.Map;

/**
 * @author: baiMl
 * @title: TopicConfig
 * @projectName: 海联技术中台V2.0
 * @depart 软件事业部
 * @description:
 * @date: 2022/5/18 15:33
 */
@Configuration(proxyBeanMethods = false)
@ConfigurationProperties(prefix = "kafka")
public class TopicConfig {
    private final Map<String, String> topics = new HashMap<>();

    public Map<String, String> getTopics() {
        return topics;
    }

    public String getTopic(String key) {
        return topics.get(key);
    }

}
